package com.xiaoshu.controller;

import com.xiaoshu.aop.LevelRecordAnnotation;
import com.xiaoshu.common.Result;
import com.xiaoshu.common.ResultGenerator;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * 功能说明：
 * com.xiaoshu.controller
 *
 * <p>
 * Original @Author: deane.jia-贾亮亮,2021/6/15 9:23
 * <p>
 * Copyright (C)2012-2021 小树盛凯科技 All rights reserved.
 */
@RestController
@RequestMapping(value = "/daily")
@Slf4j
@Api(value = "日常管理")
public class DailyServerController {

    @GetMapping(value = "/ClockIn")
    @ApiOperation(value = "每日打卡")
    @LevelRecordAnnotation(value = "ClockIn")
    public Result dailyClockIn(@RequestParam(value = "userId") String userId){
        log.info("[Daily Clock in] daily sign in userId :{}", userId);
        return ResultGenerator.success();
    }


    @GetMapping(value = "/Sign")
    @ApiOperation(value = "每日签到")
    @LevelRecordAnnotation(value = "SignIn")
    public Result dailySignIn(@RequestParam(value = "userId") String userId){
        log.info("[Daily Sign in] daily sign in userId :{}", userId);
        return ResultGenerator.success();
    }

}
